Security News
JSR Working Group Kicks Off with Ambitious Roadmap and Plans for Open Governance
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
@theme-ui/core
Advanced tools
[![Minified Size on Bundlephobia](https://badgen.net/bundlephobia/minzip/@theme-ui/core)](https://bundlephobia.com/package/@theme-ui/core)
@theme-ui/core
provides minimal React support for lightweight usage.
npm i @theme-ui/core @emotion/react
/** @jsxImportSource @theme-ui/core */
import { ThemeProvider } from '@theme-ui/core'
export function App() {
return (
<ThemeProvider theme={{ colors: { primary: '#33e' } }}>
<h1 sx={{ color: 'primary' }}>Hello</h1>
</ThemeProvider>
)
}
If you already use theme-ui
package, the batteries-included version of Theme
UI, you don't need to install @theme-ui/core
separately — it's already in your
node_modules, and theme-ui
reexports everything from it.
jsx
— JSX function to create React elements supporting sx
propThemeProvider
— a context provideruseThemeUI
— a hook to access your thememerge
— an utility function to deeply merge themes togetherNote that @theme-ui/core
doesn’t add global or root styles to
<html>
/<body>
. Refer to the
Global Styles docs for how to add
global styles.
As @theme-ui/core
defines jsx
function and types for it, you can use it to
configure JSX runtime without installing theme-ui
package.
/jsx-runtime
jsx
jsxs
/jsx-dev-runtime
jsxDEV
v0.15.7 (Thu Mar 30 2023)
FAQs
[![Minified Size on Bundlephobia](https://badgen.net/bundlephobia/minzip/@theme-ui/core)](https://bundlephobia.com/package/@theme-ui/core)
The npm package @theme-ui/core receives a total of 59,700 weekly downloads. As such, @theme-ui/core popularity was classified as popular.
We found that @theme-ui/core demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
Security News
Research
An advanced npm supply chain attack is leveraging Ethereum smart contracts for decentralized, persistent malware control, evading traditional defenses.
Security News
Research
Attackers are impersonating Sindre Sorhus on npm with a fake 'chalk-node' package containing a malicious backdoor to compromise developers' projects.